package com.wicket.okrcalc.web.contorller;

import cn.hutool.core.bean.BeanUtil;
import com.github.pagehelper.Page;
import com.github.pagehelper.page.PageMethod;
import com.wicket.okrcalc.biz.service.AchievementDockService;
import com.wicket.okrcalc.biz.service.dto.req.*;
import com.wicket.okrcalc.biz.service.dto.res.*;
import com.wicket.okrcalc.common.ro.OkrResult;
import com.wicket.okrcalc.common.util.CommonFunctionHelper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ：
 * @date ：
 *
 *
 * @version 1.0
 */
@RestController
@RequestMapping("/calc/achievementDock/")
public class AchievementDockController {

  @Autowired
  AchievementDockService achievementDockService;
/**
   * D4执行按成果类型或成果等级统计成果数(公共)
   */
    @PostMapping("implementQueryAchievementByTypeOrGraceCom")
    public OkrResult<ImplementQueryAchievementByTypeOrGraceComRespDto> implementQueryAchievementByTypeOrGraceCom(@RequestBody @Validated ImplementQueryAchievementByTypeOrGraceComReqDto reqDTO){
    return OkrResult.success(achievementDockService.implementQueryAchievementByTypeOrGraceCom(reqDTO));
    }
/**
   * D4执行绩效按成果类型或成果等级统计成果数(公共)
   */
    @PostMapping("implementPerfAchievementByTypeOrGraceCom")
    public OkrResult<ImplementPerfAchievementByTypeOrGraceComRespDto> implementPerfAchievementByTypeOrGraceCom(@RequestBody @Validated ImplementPerfAchievementByTypeOrGraceComReqDto reqDTO){
    return OkrResult.success(achievementDockService.implementPerfAchievementByTypeOrGraceCom(reqDTO));
    }
}
